package com.xhwl.centiotdata.service;

import com.alibaba.fastjson.JSONObject;
import com.xhwl.common.pojo.cent.security.PatrollingLine;
import org.springframework.web.bind.annotation.*;

import java.util.List;

/**
 * Falcon.cao @Copyright (C), 2022, 兴海物联
 * Date: 2022/8/9 10:24
 * Description: 包信息
 */
@RestController
public interface ISecurityPatrolService {

    @PostMapping("/iot-patrol/line/create")
    String onAddingPatrolsLine(@RequestPart("patrollingLine") PatrollingLine line, @RequestPart("nodeIds") List<String> nodeIds);

    @PostMapping("/iot-patrol/line/update")
    String onUpdatePatrolsLine(@RequestPart("patrollingLine") PatrollingLine line, @RequestPart("oldName") String oldName, @RequestPart("nodeIds") List<String> nodeIds);

    @PostMapping("/iot-patrol/line/delete")
    String onDeletePatrolsLine(@RequestParam("projectId") Integer projectId, @RequestParam("platformId") String platformId);

    @PostMapping("/iot-patrol/plan/create")
    String onAddingPatrolsPlan(@RequestPart("map") JSONObject map);

    @PostMapping("/iot-patrol/plan/update")
    String onUpdatePatrolsPlan(@RequestPart("map") JSONObject map);

    @PostMapping("/iot-patrol/plan/delete")
    String onDeletePatrolsPlan(@RequestParam("projectId") Integer projectId, @RequestParam("platformId") String platformId);

    @PostMapping("/iot-patrol/check-records")
    String onGetterCheckRecord(@RequestPart("map") JSONObject map);

}
